package com.xinyue.game.server.common;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

@Configuration
@ConfigurationProperties(prefix = "xinyue.game")
public class NettyServerConfig {

	private int port = 8088;
	/** 工作线程的数量 **/
	private int workThreads = 4;
	private int sendBuffSize = 65535;
	private int receiveBuffSize = 65535;
	/** 连接最大空闲时间,单位秒 */
	private int maxIdleTime = 60;

	public int getPort() {
		return port;
	}

	public void setPort(int port) {
		this.port = port;
	}

	public int getWorkThreads() {
		return workThreads;
	}

	public void setWorkThreads(int workThreads) {
		this.workThreads = workThreads;
	}

	public int getSendBuffSize() {
		return sendBuffSize;
	}

	public void setSendBuffSize(int sendBuffSize) {
		this.sendBuffSize = sendBuffSize;
	}

	public int getReceiveBuffSize() {
		return receiveBuffSize;
	}

	public void setReceiveBuffSize(int receiveBuffSize) {
		this.receiveBuffSize = receiveBuffSize;
	}

	public int getMaxIdleTime() {
		return maxIdleTime;
	}

	public void setMaxIdleTime(int maxIdleTime) {
		this.maxIdleTime = maxIdleTime;
	}

}
